/*package kr.jin.zeroprojectone;

import java.util.ArrayList;

import org.achartengine.model.TimeSeries;

import android.app.Activity;
import android.database.Cursor;
import android.database.sqlite.SQLiteDatabase;
import android.os.Bundle;
import android.os.Handler;
import android.widget.TextView;
import android.widget.Toast;

public class GraphLine1 extends Activity {
	TextView tv1;
	TextView tv2;
	StringBuffer sb;
	StringBuffer sb2;
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.graph_line1);
		
		tv1 = (TextView)findViewById(R.id.tvtv);
		tv2 = (TextView)findViewById(R.id.tvtvtv);
		ChartThread thread = new ChartThread();
		thread.setDaemon(true);
		thread.start();
	}
	class ChartThread extends Thread{
		@Override
		public void run() {
			openChart();
		}
	}
	
	private void openChart(){
		DBHelper dbHelper= new DBHelper(this);
		SQLiteDatabase db = dbHelper.getReadableDatabase();
		Cursor c1 = db.rawQuery("SELECT * FROM step1", null);	
		c1.moveToFirst();	
		int r=c1.getCount();
		Toast.makeText(this, ""+r, Toast.LENGTH_SHORT).show();
		//TimeSeries stepOneChart = new TimeSeries("Activiry");
		ArrayList<String> dateList = new ArrayList<String>();
		ArrayList<String> timeList = new ArrayList<String>();	
		String date="";
		Long timeNum = 0L;
		String time="";
		int i=1;
		
		while(i<c1.getCount()){
			date = c1.getString(1);
			dateList.add(date);
			while(date==c1.getString(1)){
				timeNum =+ c1.getLong(3);
				c1.moveToNext();
				i++;
			}
			timeList.add(String.format("%d", timeNum/1000/60));
			
		}
		sb = new StringBuffer();
		sb2 = new StringBuffer();
		for(int j=0; j<dateList.size(); j++){
			sb.append(dateList.get(j)+"\n");
			sb2.append(timeList.get(j)+"\n");
		}
		handler.sendEmptyMessage(0);
		
	}
	
	Handler handler = new Handler(){
		public void handleMessage(android.os.Message msg) {
			tv1.setText(sb);
			tv2.setText(sb2);
		}
	};
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
}
*/